package com.tengfei.main.plan.domain.bo;

import com.tengfei.common.core.validate.AddGroup;
import com.tengfei.common.core.validate.EditGroup;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * 学习计划业务对象 sp_plan
 *
 * @author tengfei
 * @date 2022-08-01
 */

@Data
@ApiModel("学习计划业务对象")
public class PlanBo {

    /**
     * 计划名称
     */
    @ApiModelProperty(value = "计划Id")
    @NotNull(message = "计划Id不能为空", groups = { EditGroup.class })
    private Long planId;

    /**
     * 计划名称
     */
    @ApiModelProperty(value = "计划名称", required = true)
    @NotBlank(message = "计划名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String planName;

    /**
     * 计划描述
     */
    @ApiModelProperty(value = "计划描述")
    private String planDesc;

    /**
     * 计划开始时间
     */
    @ApiModelProperty(value = "计划开始时间", required = true)
    @NotNull(message = "计划开始时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date planStartTime;

    /**
     * 计划结束时间
     */
    @ApiModelProperty(value = "计划结束时间", required = true)
    @NotNull(message = "计划结束时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private Date planEndTime;

    /**
     * 计划最低完成度
     */
    @ApiModelProperty(value = "计划最低完成度", required = true)
    @NotNull(message = "计划最低完成度不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer planMinDegree;

    /**
     * 开启计划
     */
    @ApiModelProperty(value = "是否开启计划")
    @NotNull(message = "是否开启计划不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer planToStart;


}
